import requests


headers = {
    "Host": "gw.m.163.com",
    "x-b3-sampled": "1",
    "user-c": "5pCc57Si",
    "x-nr-trace-id": "1754985785748_10786916384_6096FF4D-18DD-445F-B2B9-47ACE5F866AC",
    "user-appid": "zbCHbGcGkGiMBRRJXmZMeA==",
    "user-agent": "NewsApp/114.1 iOS/15.8.3 (iPhone9,1)",
    "user-da": "0s29TN7+3eTrM8C8wV/0sS/myospKKFNrlDwii9KBnJesXabOlbbSbEXzgUS8XT0",
    "user-l": "5/CoJrL0lbfTsMjK3w2XAlVl/OLLltnoLxcjYhqqZUGVkM716wGjyeQ4IF/UeJM6",
    "user-lc": "sQoTw9pj4F14cmuXJo18Kg==",
    "x-nr-sign": "9f71b0a34467b5273f143190de62c97b",
    "user-n": "6QlSYk8QXf0OQ4AWdVtY7/jhya3RJrFegeb7075ultGqMsUK4MKsGp2OB35xS259",
    "user-u": "",
    "user-d": "5ZTcS4n5d+GTMUNk1PcdqC82zcosjSDixp86NzzyyL3O6++rDhiqE1uSL40Ouoep",
    "accept-language": "zh-CN,zh-Hans;q=0.9",
    "x-nr-ts": "1754985785756",
    "accept": "*/*",
    "user-sid": "izyOZBRDE8VaykLy9xwiiAAkQDpTx2kRHwX7sgi61X295wXg/ofXD8vV2G3uCT8Z",
    "x-b3-spanid": "0",
}
url = "https://gw.m.163.com/nc/api/v1/search/flow/comp"
params = {
    "deviceId": "5ZTcS4n5d+GTMUNk1PcdqC82zcosjSDixp86NzzyyL3O6++rDhiqE1uSL40Ouoep",
    "version": "114.1",
    "channel": "5pCc57Si",
    "canal": "appstore",
    "qId": "",
    "tabname": "",
    "ts": "1754985785",
    "lat": "",
    "lon": "",
    "sign": "3P7TnK+A5cN/SuHH4zyvo0+PbHsp921hmXI43pQH+g948ErR02zJ6/KXOnxX046I",
    "spever": "false",
    "open": "",
    "openpath": "",
    "dtype": "0",
    "start": "MA==",
    "limit": "20",
    "q": "54m55pyX5pmu",
}
response = requests.get(url, headers=headers, params=params)

print(response.text)
print(response)
